package cn.xie.blog.serviceuser.service;

import cn.xie.blog.model.common.param.login.LoginParam;
import cn.xie.blog.model.common.param.registered.RegisteredParam;
import cn.xie.blog.model.common.vo.UserDetailsVO;
import jakarta.servlet.http.HttpServletRequest;
import org.springframework.web.server.ServerWebExchange;

import java.io.Serializable;
import java.net.http.HttpRequest;

/**
 * @author: xiaoxie
 * create: 2025-04-22 20:56
 * @BelongsProject: blog-parent
 * @BelongsPackage: cn.xie.blog.serviceuser.service
 * description:
 */

public interface UserService extends Serializable {
    /**
     * @description: 登录
     * @author: xiaoxie
     * @date: 2025/4/22 下午9:00
     * @param: [loginParam]
     * @return: java.lang.Long
     **/
   String login(LoginParam loginParam);

    /**
     * @description: 注册
     * @author: xiaoxie
     * @date: 2025/4/22 下午9:47
     * @param: [registeredParam]
     * @return: java.lang.Boolean
     **/
    Boolean registered(RegisteredParam registeredParam);

    /**
     * @description: 获取邮箱的验证码
     * @author: xiaoxie
     * @date: 2025/4/22 下午9:56
     * @param: []
     * @return: java.lang.Boolean
     **/
    Boolean getCode(String mail);
    /**
     * @description: 根据用户id查询数据库
     * @author: xiaoxie
     * @date: 2025/4/24 下午3:40
     * @param: [userId]
     * @return: cn.xie.blog.model.common.vo.UserDetailsVO
     **/
    UserDetailsVO getUserDetailsById(String userId);

    /**
     * @description: 用户注销
     * @author: xiaoxie
     * @date: 2025/5/1 下午11:24
     * @param: []
     * @return: java.lang.Boolean
     **/
    Boolean logout();
}
